<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>奇数和</title>
    <script type="text/javascript">
        var sum = 0;
        for(i=1;i<=100;i++)
            {
            sum+=i;
        }
        document.write("100以内奇数的总和是"+sum);

    </script>
</head>
<body>

</body>
</html>
